
/** require 配置信息 */
require.config({
    urlArgs: "r="+new Date().getTime(),
    baseUrl: "/resources/js/",
    paths:{
        "text":"commons/text",
        "css":"commons/css.min",
        "vue":"commons/vue",
        "router":"commons/router",
        "tasks":"compent/tasks",
        "show":"compent/show",
        "info":"compent/info",
        "ELEMENT":"commons/element",
        "jquery":"commons/jquery-3.2.1.min",

        "tasksHtml":"/pages/tasks.html",
        "showHtml":"/pages/show.html",
        "infoHtml":"/pages/info.html"
    },
    shim:{
        'show':{
            deps:['css!/resources/css/tasks/show.css']
        },
        'tasks':{
            deps:['css!/resources/css/tasks/tasks.css']
        }
    }
});


/** 加载信息 */
require(["vue","router","ELEMENT"],function (Vue,VueRouter,ELEMENT) {
    //设置vue警告日志输出 false不输出
    Vue.config.productionTip = false;
    Vue.use(ELEMENT);
    Vue.use(VueRouter);

    //路由配置
    const routes = [
        {
            path: '/tasks', component: resolve => require(['tasks'], resolve)
        },
        {
            path:'/show',component: resolve => require(['show'], resolve)
        },{
            path:'/infos',component: resolve => require(['info'], resolve)
        }
    ]
    const router = new VueRouter({
        routes: routes
    });
    new Vue({
        router:router,
    }).$mount("#main");
});
